package edu.wayne.cs.csc4110.hw6.interfaces.state;

import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;

import edu.wayne.cs.csc4110.hw6.interfaces.user.User;

public interface State {

	/**
	 * Prints out the state the the specified output stream
	 * 
	 * @param out
	 *            , the output stream to print the current state
	 * @param obj
	 *            the object that is stored
	 * 
	 */
	public boolean storeState(OutputStream out, Object obj) throws IOException;

	/**
	 * Creates a state from an inputstream
	 * 
	 * @param in
	 *            the InputStream that carries the data to create the new state
	 * @return true if the state was created
	 * @throws ClassNotFoundException
	 */
	public User createState(InputStream in) throws IOException,
			ClassNotFoundException;
}
